package hiatao.puzzle.adapter;

import haitao.puzzle.R;
import hiatao.puzzle.entity.User;
import hiatao.puzzle.utils.ImageUtils;
import hiatao.puzzle.utils.Tools;
import java.util.ArrayList;
import java.util.List;
import android.content.Context;
import android.os.Handler;
import android.text.method.LinkMovementMethod;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.ImageView;
import android.widget.TextView;

public class NoticeAdapter extends BaseAdapter {

	private LayoutInflater mInflater;
	private Context context;
	
	public NoticeAdapter(Context context) {
		this.context = context;
		this.mInflater = LayoutInflater.from(context);
	}

	@Override
	public int getCount() {
		return 1;
	}

	@Override
	public Object getItem(int position) {
		return null;
	}

	@Override
	public long getItemId(int position) {
		return position;
	}

	
	
	@Override
	public View getView(int position, View convertView, ViewGroup parent) {
		PicModelHodler holder ;
		if(convertView == null){
			holder = new PicModelHodler();
			convertView = mInflater.inflate(R.layout.list_notice, parent,false);
/*			holder.image = (ImageView) convertView.findViewById(R.id.head_image);
			holder.rank_img = (ImageView) convertView.findViewById(R.id.rank_img);
			holder.name_tv = (TextView) convertView.findViewById(R.id.name_tv);
			holder.zuan_tv = (TextView) convertView.findViewById(R.id.zuan_tv);
			holder.follow_tv = (TextView) convertView.findViewById(R.id.follow_tv);
			holder.intro_tv = (TextView) convertView.findViewById(R.id.intro_tv);*/
			holder.intro_tv = (TextView) convertView.findViewById(R.id.intro_tv);
			convertView.setTag(holder);
		}
		else{
			holder = (PicModelHodler) convertView.getTag();
		}
		//holder.intro_tv.setMovementMethod(LinkMovementMethod.getInstance()); 
		return convertView;
	}

	private final class PicModelHodler {
/*		public ImageView image;
		public ImageView rank_img;
		public TextView name_tv;
		public TextView zuan_tv;
		public TextView follow_tv;
		public TextView intro_tv;*/
		public TextView intro_tv;
	}
}
